package com.kqb.sgcommon.file.oss;

import com.kqb.sgcommon.base.response.FileUploadResult;
import org.springframework.web.multipart.MultipartFile;

import java.io.InputStream;
import java.util.List;

/**
 * @author 杉果树皮
 */
public interface FileService {
    /**
     * 文件上传到oss
     *
     * @param path
     * @param inputStream
     * @return
     */
    boolean upload(String path, InputStream inputStream);

    InputStream download(String path);

    boolean delete(String path);

    FileUploadResult uploadImage(String module, MultipartFile file);

    List<FileUploadResult> batchUploadImages(String module, List<MultipartFile> files);

    String externalPath(String path);
}
